package com.example.testapp

class CoreAlaki {
    private var systemState: String = "stopped"
    private var configMap: MutableMap<String, String> = mutableMapOf()
    
    fun startSystem(): Boolean {
        systemState = "running"
        initializeDefaultConfig()
        return true
    }
    
    fun stopSystem() {
        systemState = "stopped"
        configMap.clear()
    }
    
    private fun initializeDefaultConfig() {
        configMap["timeout"] = "30000"
        configMap["maxConnections"] = "100"
        configMap["bufferSize"] = "8192"
    }
    
    fun getSystemState(): String {
        return systemState
    }
    
    fun setConfig(key: String, value: String) {
        configMap[key] = value
    }
    
    fun getConfig(key: String): String? {
        return configMap[key]
    }
    
    fun getAllConfigs(): Map<String, String> {
        return configMap.toMap()
    }
}